Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Backport 5.11.x] Comment out runAsUser and runAsGroup in values.yaml #626

Merged
merged 1 commit into from
Jan 24, 2025

Conversation

sourcegraph-release-bot
Copy link
Collaborator

Since PR 2456 in the Sourcegraph repo, support for the default value of -1 for the KUBERNETES_RUN_AS_USER and KUBERNETES_RUN_AS_GROUP Executor environment variables has been removed - those environment variables now require either blank values or non-negative integers in the range [0, 2147483647], to match the range for Unix UIDs and GIDs.

This PR updates charts/sourcegraph-executor/k8s/values.yaml so that runAsUser and runAsGroup are commented out, with comments to explain that the user can uncomment them to use them. Having those settings commented out causes KUBERNETES_RUN_AS_USER and KUBERNETES_RUN_AS_GROUP in charts/sourcegraph-executor/k8s/templates/executor.ConfigMap.yaml to be blank, which is the new default value.

Checklist

Test plan

A Helm deployment is successful and does not fail with errors like KUBERNETES_RUN_AS_USER must be a UID in the range 0 to 2,147,483,647, but got "-1".

Backport e215bde from #618

Since [PR 2456](sourcegraph/sourcegraph#2456) in
the Sourcegraph repo, support for the default value of -1 for the
`KUBERNETES_RUN_AS_USER` and `KUBERNETES_RUN_AS_GROUP` Executor
environment variables has been removed - those environment variables now
require either blank values or non-negative integers in the range [0,
2147483647], to match the range for Unix UIDs and GIDs.

This PR updates `charts/sourcegraph-executor/k8s/values.yaml` so that
`runAsUser` and `runAsGroup` are commented out, with comments to explain
that the user can uncomment them to use them. Having those settings
commented out causes `KUBERNETES_RUN_AS_USER` and
`KUBERNETES_RUN_AS_GROUP` in
`charts/sourcegraph-executor/k8s/templates/executor.ConfigMap.yaml` to
be blank, which is the new default value.

### Checklist

- [ ] Follow the [manual testing
process](https://github.com/sourcegraph/deploy-sourcegraph-helm/blob/main/TEST.md)
- [ ] Update
[changelog](https://github.com/sourcegraph/deploy-sourcegraph-helm/blob/main/charts/sourcegraph/CHANGELOG.md)
- [ ] Update [Kubernetes update
doc](https://docs.sourcegraph.com/admin/updates/kubernetes)

### Test plan

A Helm deployment is successful and does not fail with errors like
`KUBERNETES_RUN_AS_USER must be a UID in the range 0 to 2,147,483,647,
but got "-1".`

(cherry picked from commit e215bde)
Copy link
Contributor

@peterguy peterguy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Go, go, gadget backport!

@peterguy peterguy merged commit ef06f82 into 5.11.x Jan 24, 2025
7 checks passed
@peterguy peterguy deleted the backport-618-to-5.11.x branch January 24, 2025 02:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants